1. Field of the Invention
This invention relates to a debug method and a debug system for reproducing an error which has occurred in programs executed in a parallel manner in a multiprocessor system because of a timing error between the programs.
2. Description of the Related Art
Various debug methods for programs have recently been developed, which means that general debug methods have been established. For example, the debug methods include breakpoint setting, single-step execution, symbolic debug, etc. The breakpoint setting is a technique for setting a point of time at which control is shifted to a debugger in a case where it advances to a designated subroutine, etc. The single-step execution is a technique for executing programs in units of a single command. The symbolic debug is a technique for performing debug in accordance with a source program, in which technique the process of debug is designated by a subroutine or a variable.
Those debug methods, however, are employed in single processors, and such debug methods as applicable to multiprocessors are now being developed.
In particular, in the case of programs executed by processors simultaneously in a parallel manner, it is highly possible that when an error has occurred, it cannot be reproduced because of a subtle shift of timing in the execution of the programs. This being so, debug is more and more difficult.
For example, suppose that programs are executed in a parallel manner by processors 11a-11c incorporated in a multiprocessor system as shown in FIG. 1.
If one (e.g. 13c) of exclusive processes 13a-13c included in the programs has a bug, the exclusive process 13c is not normally executed, thereby causing an error due to a timing shift between the exclusive processes 13b and 13c. In such a case, it is necessary to reproduce the error by executing a debugger while synchronizing the processors 11a-11c. Thus, the efficiency of debug is inevitably low. Further, in a worst case, it is not possible to reproduce the error and debug the bug.
As explained above, when an error has occurred in programs executed in a parallel manner by processors, because of a timing shift between the processors, it is very difficult for the conventional debug system to debug a bug in the programs, or it is not possible for the same to reproduce and hence debug the bug.